package com.banyiyi.simple.pattern.proxy;

/**
 * @ClassName Client
 * @Description TODO
 * @Author yangwm
 * @Date 2023/2/20 14:31
 * @Version 1.0
 */
public class Client {

    public static void main(String[] args) {
        Database database = new Mysql();
        DatabaseHandler handler = new DatabaseHandler(database);
        // 获取代理
        Database proxy = handler.getProxy();
        proxy.create();
        proxy.search();
        proxy.update();
        proxy.delete();
    }
}
